# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.AndroidPublisher.V3.Model.ApkTargeting do
  @moduledoc """
  Represents a set of apk-level targetings.

  ## Attributes

  *   `abiTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.AbiTargeting.t`, *default:* `nil`) - The abi that the apk targets
  *   `languageTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.LanguageTargeting.t`, *default:* `nil`) - The language that the apk targets
  *   `multiAbiTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.MultiAbiTargeting.t`, *default:* `nil`) - Multi-api-level targeting.
  *   `screenDensityTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.ScreenDensityTargeting.t`, *default:* `nil`) - The screen density that this apk supports.
  *   `sdkVersionTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.SdkVersionTargeting.t`, *default:* `nil`) - The sdk version that the apk targets
  *   `textureCompressionFormatTargeting` (*type:* `GoogleApi.AndroidPublisher.V3.Model.TextureCompressionFormatTargeting.t`, *default:* `nil`) - Texture-compression-format-level targeting
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :abiTargeting => GoogleApi.AndroidPublisher.V3.Model.AbiTargeting.t() | nil,
          :languageTargeting => GoogleApi.AndroidPublisher.V3.Model.LanguageTargeting.t() | nil,
          :multiAbiTargeting => GoogleApi.AndroidPublisher.V3.Model.MultiAbiTargeting.t() | nil,
          :screenDensityTargeting =>
            GoogleApi.AndroidPublisher.V3.Model.ScreenDensityTargeting.t() | nil,
          :sdkVersionTargeting =>
            GoogleApi.AndroidPublisher.V3.Model.SdkVersionTargeting.t() | nil,
          :textureCompressionFormatTargeting =>
            GoogleApi.AndroidPublisher.V3.Model.TextureCompressionFormatTargeting.t() | nil
        }

  field(:abiTargeting, as: GoogleApi.AndroidPublisher.V3.Model.AbiTargeting)
  field(:languageTargeting, as: GoogleApi.AndroidPublisher.V3.Model.LanguageTargeting)
  field(:multiAbiTargeting, as: GoogleApi.AndroidPublisher.V3.Model.MultiAbiTargeting)
  field(:screenDensityTargeting, as: GoogleApi.AndroidPublisher.V3.Model.ScreenDensityTargeting)
  field(:sdkVersionTargeting, as: GoogleApi.AndroidPublisher.V3.Model.SdkVersionTargeting)

  field(:textureCompressionFormatTargeting,
    as: GoogleApi.AndroidPublisher.V3.Model.TextureCompressionFormatTargeting
  )
end

defimpl Poison.Decoder, for: GoogleApi.AndroidPublisher.V3.Model.ApkTargeting do
  def decode(value, options) do
    GoogleApi.AndroidPublisher.V3.Model.ApkTargeting.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.AndroidPublisher.V3.Model.ApkTargeting do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
